package com.yjzx.util.common.util.unmodifiable;

import com.yjzx.util.common.util.collection.EmptyUtils;

import java.lang.reflect.Method;
import java.util.Collections;
import java.util.List;

/**
 * @author yjzx
 * @date 2024/8/14
 * @description UnmodifiableObject
 */
public class UnmodifiableObject {
    /**
     * 排除方法
     */
    private final List<Method> excludeMethods;
    /**
     * 包含方法
     */
    private final List<Method> includeMethods;

    UnmodifiableObject() {
        this(Collections.emptyList(), Collections.emptyList());
    }

    UnmodifiableObject(List<Method> excludeMethods, List<Method> includeMethods) {
        this.excludeMethods = EmptyUtils.isEmpty(excludeMethods)? Collections.emptyList() : excludeMethods;
        this.includeMethods = EmptyUtils.isEmpty(includeMethods) ? Collections.emptyList() : includeMethods;
    }

    public List<Method> getExcludeMethods() {
        return excludeMethods;
    }


    public List<Method> getIncludeMethods() {
        return includeMethods;
    }



}
